#include "socketsync.h"
#include "socketsync_p.h"

SocketSync::SocketSync(quint16 port, QObject *parent) :
    QObject(parent)
  , d(new SocketSyncPrivate)
{
    d->setUdpPort(port);
}

SocketSync::~SocketSync()
{
    delete d;
    d = NULL;
}

int SocketSync::sendUdpMessage(QString msg, QString ip, quint16 port, QString &result)
{
    return d->sendUdpMessage(msg, ip, port, result);
}

QUdpSocket* SocketSync::udpsocket()
{
    return d->udpsocket();
}
